<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libBigWig: bigWig.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">libBigWig
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#define-members">Macros</a> &#124;
<a href="#enum-members">Enumerations</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">bigWig.h File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &quot;<a class="el" href="bigWigIO_8h_source.html">bigWigIO.h</a>&quot;</code><br />
<code>#include &quot;<a class="el" href="bwValues_8h_source.html">bwValues.h</a>&quot;</code><br />
<code>#include &lt;inttypes.h&gt;</code><br />
<code>#include &lt;zlib.h&gt;</code><br />
</div>
<p><a href="bigWig_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbwZoomHdr__t.html">bwZoomHdr_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">BigWig files have multiple "zoom" levels, each of which has its own header. This hold those headers.  <a href="structbwZoomHdr__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbigWigHdr__t.html">bigWigHdr_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">The header section of a bigWig file.  <a href="structbigWigHdr__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structchromList__t.html">chromList_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Holds the chromosomes and their lengths.  <a href="structchromList__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbwWriteBuffer__t.html">bwWriteBuffer_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">This is only needed for writing bigWig files (and won't be created otherwise) This should be removed from <a class="el" href="bigWig_8h.html">bigWig.h</a>.  <a href="structbwWriteBuffer__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">A structure that holds everything needed to access a bigWig file.  <a href="structbigWigFile__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Holds interval:value associations.  <a href="structbwOverlappingIntervals__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbbOverlappingEntries__t.html">bbOverlappingEntries_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Holds interval:str associations.  <a href="structbbOverlappingEntries__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">A structure to hold iterations One of intervals and entries should be used to access records from bigWig or bigBed files, respectively.  <a href="structbwOverlapIterator__t.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:afe870db159b3eed39c32be30ccc73c4e"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#afe870db159b3eed39c32be30ccc73c4e">LIBBIGWIG_VERSION</a>&#160;&#160;&#160;0.4.5</td></tr>
<tr class="separator:afe870db159b3eed39c32be30ccc73c4e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac2496b5d01c469f90f790b933f31d0d4"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#ac2496b5d01c469f90f790b933f31d0d4">LIBBIGWIG_CURL</a>&#160;&#160;&#160;1</td></tr>
<tr class="separator:ac2496b5d01c469f90f790b933f31d0d4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abc55570005e3349503ee7f6d5267eb8a"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#abc55570005e3349503ee7f6d5267eb8a">BIGWIG_MAGIC</a>&#160;&#160;&#160;0x888FFC26</td></tr>
<tr class="separator:abc55570005e3349503ee7f6d5267eb8a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a17aeac12ade93f0b26a203be7beacc68"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a17aeac12ade93f0b26a203be7beacc68">BIGBED_MAGIC</a>&#160;&#160;&#160;0x8789F2EB</td></tr>
<tr class="separator:a17aeac12ade93f0b26a203be7beacc68"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3d7d5829abe177defc549aaddd59e121"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a3d7d5829abe177defc549aaddd59e121">CIRTREE_MAGIC</a>&#160;&#160;&#160;0x78ca8c91</td></tr>
<tr class="separator:a3d7d5829abe177defc549aaddd59e121"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a28c6eb6ee75c6082e8df04dba8c7f32e"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a28c6eb6ee75c6082e8df04dba8c7f32e">IDX_MAGIC</a>&#160;&#160;&#160;0x2468ace0</td></tr>
<tr class="separator:a28c6eb6ee75c6082e8df04dba8c7f32e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac0d6303cef22d415a53d150be8f06623"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#ac0d6303cef22d415a53d150be8f06623">DEFAULT_nCHILDREN</a>&#160;&#160;&#160;64</td></tr>
<tr class="separator:ac0d6303cef22d415a53d150be8f06623"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a46a626f6d8b24b07925d82cde2175864"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a46a626f6d8b24b07925d82cde2175864">DEFAULT_BLOCKSIZE</a>&#160;&#160;&#160;32768</td></tr>
<tr class="separator:a46a626f6d8b24b07925d82cde2175864"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:aa3e01d7486887aa111417b688bc1a22c"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a> { <br />
&#160;&#160;<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca3dc84a7fe13f0c3b468dd1fcf456ee3a">doesNotExist</a> = -1, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca73aa25ce744f80bc0f1c0e991a509638">mean</a> = 0, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22cae478d4d7f90177e87ed05369ad732b25">average</a> = 0, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22cac7a4dba588d32e11eaa063e51c491387">stdev</a> = 1, 
<br />
&#160;&#160;<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22cac10cab3311c9fe30fbabf9137cd40d57">dev</a> = 1, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca6eba708e9255d1bb06879b30b47422ff">max</a> = 2, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca1e491e9b59d4f6891eb2929589487dfc">min</a> = 3, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22caf866615ac99c2e47027ea68849ef849f">cov</a> = 4, 
<br />
&#160;&#160;<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca02bbe932c03913324065a5318a16e715">coverage</a> = 4, 
<a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22ca3693895373771b9806a9775d16d1198b">sum</a> = 5
<br />
 }</td></tr>
<tr class="separator:aa3e01d7486887aa111417b688bc1a22c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:a4aa7fa5e6146a2719feb8815c9bccd62"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a4aa7fa5e6146a2719feb8815c9bccd62">bwInit</a> (size_t bufSize)</td></tr>
<tr class="memdesc:a4aa7fa5e6146a2719feb8815c9bccd62"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes curl and global variables. This <em>MUST</em> be called before other functions (at least if you want to connect to remote files). For remote file, curl must be initialized and regions of a file read into an internal buffer. If the buffer is too small then an excessive number of connections will be made. If the buffer is too large than more data than required is fetched. 128KiB is likely sufficient for most needs.  <a href="bigWig_8h.html#a4aa7fa5e6146a2719feb8815c9bccd62">More...</a><br /></td></tr>
<tr class="separator:a4aa7fa5e6146a2719feb8815c9bccd62"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af1f5d8a9bf0a96034b2ba3f3b3ee679a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#af1f5d8a9bf0a96034b2ba3f3b3ee679a">bwCleanup</a> (void)</td></tr>
<tr class="memdesc:af1f5d8a9bf0a96034b2ba3f3b3ee679a"><td class="mdescLeft">&#160;</td><td class="mdescRight">The counterpart to bwInit, this cleans up curl.  <a href="bigWig_8h.html#af1f5d8a9bf0a96034b2ba3f3b3ee679a">More...</a><br /></td></tr>
<tr class="separator:af1f5d8a9bf0a96034b2ba3f3b3ee679a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a83cb23e15fed718ba77576e41865dab9"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a83cb23e15fed718ba77576e41865dab9">bwIsBigWig</a> (char *fname, CURLcode(*callBack)(CURL *))</td></tr>
<tr class="memdesc:a83cb23e15fed718ba77576e41865dab9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determine if a file is a bigWig file. This function will quickly check either local or remote files to determine if they appear to be valid bigWig files. This can be determined by reading the first 4 bytes of the file.  <a href="bigWig_8h.html#a83cb23e15fed718ba77576e41865dab9">More...</a><br /></td></tr>
<tr class="separator:a83cb23e15fed718ba77576e41865dab9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a592fb218273e1f18d97448c88588df19"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a592fb218273e1f18d97448c88588df19">bbIsBigBed</a> (char *fname, CURLcode(*callBack)(CURL *))</td></tr>
<tr class="memdesc:a592fb218273e1f18d97448c88588df19"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determine is a file is a bigBed file. This function will quickly check either local or remote files to determine if they appear to be valid bigWig files. This can be determined by reading the first 4 bytes of the file.  <a href="bigWig_8h.html#a592fb218273e1f18d97448c88588df19">More...</a><br /></td></tr>
<tr class="separator:a592fb218273e1f18d97448c88588df19"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a55e46bf04f13da31a3971044b85c9243"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a55e46bf04f13da31a3971044b85c9243">bwOpen</a> (char *fname, CURLcode(*callBack)(CURL *), const char *mode)</td></tr>
<tr class="memdesc:a55e46bf04f13da31a3971044b85c9243"><td class="mdescLeft">&#160;</td><td class="mdescRight">Opens a local or remote bigWig file. This will open a local or remote bigWig file. Writing of local bigWig files is also supported.  <a href="bigWig_8h.html#a55e46bf04f13da31a3971044b85c9243">More...</a><br /></td></tr>
<tr class="separator:a55e46bf04f13da31a3971044b85c9243"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa1f2b92d87ce0edc52d75ce8351e03a5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#aa1f2b92d87ce0edc52d75ce8351e03a5">bbOpen</a> (char *fname, CURLcode(*callBack)(CURL *))</td></tr>
<tr class="memdesc:aa1f2b92d87ce0edc52d75ce8351e03a5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Opens a local or remote bigBed file. This will open a local or remote bigBed file. Note that this file format can only be read and NOT written!  <a href="bigWig_8h.html#aa1f2b92d87ce0edc52d75ce8351e03a5">More...</a><br /></td></tr>
<tr class="separator:aa1f2b92d87ce0edc52d75ce8351e03a5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6de19dc3a3e25e1b10a61b941f299862"><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a6de19dc3a3e25e1b10a61b941f299862">bbGetSQL</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp)</td></tr>
<tr class="memdesc:a6de19dc3a3e25e1b10a61b941f299862"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a string containing the SQL entry (or NULL). The "auto SQL" field contains the names and value types of the entries in each bigBed entry. If you need to parse a particular value out of each entry, then you'll need to first parse this.  <a href="bigWig_8h.html#a6de19dc3a3e25e1b10a61b941f299862">More...</a><br /></td></tr>
<tr class="separator:a6de19dc3a3e25e1b10a61b941f299862"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae9041b92bc3f69533fe6dc1711bbf485"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#ae9041b92bc3f69533fe6dc1711bbf485">bwClose</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp)</td></tr>
<tr class="memdesc:ae9041b92bc3f69533fe6dc1711bbf485"><td class="mdescLeft">&#160;</td><td class="mdescRight">Closes a <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> and frees up allocated memory This closes both bigWig and bigBed files.  <a href="bigWig_8h.html#ae9041b92bc3f69533fe6dc1711bbf485">More...</a><br /></td></tr>
<tr class="separator:ae9041b92bc3f69533fe6dc1711bbf485"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af017214ff795d4d738cf679cd4a55b6c"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#af017214ff795d4d738cf679cd4a55b6c">bwGetTid</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom)</td></tr>
<tr class="memdesc:af017214ff795d4d738cf679cd4a55b6c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Converts between chromosome name and ID.  <a href="bigWig_8h.html#af017214ff795d4d738cf679cd4a55b6c">More...</a><br /></td></tr>
<tr class="separator:af017214ff795d4d738cf679cd4a55b6c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6a3f9298129e7fa061707739a96b36f3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a6a3f9298129e7fa061707739a96b36f3">bwDestroyOverlappingIntervals</a> (<a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a> *o)</td></tr>
<tr class="memdesc:a6a3f9298129e7fa061707739a96b36f3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Frees space allocated by <code>bwGetOverlappingIntervals</code>  <a href="bigWig_8h.html#a6a3f9298129e7fa061707739a96b36f3">More...</a><br /></td></tr>
<tr class="separator:a6a3f9298129e7fa061707739a96b36f3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1c53fa1c835b2527afb5028d21111ff4"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a1c53fa1c835b2527afb5028d21111ff4">bbDestroyOverlappingEntries</a> (<a class="el" href="structbbOverlappingEntries__t.html">bbOverlappingEntries_t</a> *o)</td></tr>
<tr class="memdesc:a1c53fa1c835b2527afb5028d21111ff4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Frees space allocated by <code>bbGetOverlappingEntries</code>  <a href="bigWig_8h.html#a1c53fa1c835b2527afb5028d21111ff4">More...</a><br /></td></tr>
<tr class="separator:a1c53fa1c835b2527afb5028d21111ff4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa1ac8480a8fdf24c53b73970149e359b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#aa1ac8480a8fdf24c53b73970149e359b">bwGetOverlappingIntervals</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end)</td></tr>
<tr class="memdesc:aa1ac8480a8fdf24c53b73970149e359b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return bigWig entries overlapping an interval. Find all bigWig entries overlapping a range and returns them, including their associated values.  <a href="bigWig_8h.html#aa1ac8480a8fdf24c53b73970149e359b">More...</a><br /></td></tr>
<tr class="separator:aa1ac8480a8fdf24c53b73970149e359b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3ae987bbf528cc193bbbbd7536668e89"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbbOverlappingEntries__t.html">bbOverlappingEntries_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a3ae987bbf528cc193bbbbd7536668e89">bbGetOverlappingEntries</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, int withString)</td></tr>
<tr class="memdesc:a3ae987bbf528cc193bbbbd7536668e89"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return bigBed entries overlapping an interval. Find all bigBed entries overlapping a range and returns them.  <a href="bigWig_8h.html#a3ae987bbf528cc193bbbbd7536668e89">More...</a><br /></td></tr>
<tr class="separator:a3ae987bbf528cc193bbbbd7536668e89"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afaeb6115f7056b209eefa9363b409ef5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#afaeb6115f7056b209eefa9363b409ef5">bwOverlappingIntervalsIterator</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, uint32_t blocksPerIteration)</td></tr>
<tr class="memdesc:afaeb6115f7056b209eefa9363b409ef5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates an iterator over intervals in a bigWig file Iterators can be traversed with <code><a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext()</a></code> and destroyed with <code><a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy()</a></code>. Intervals are in the <code>intervals</code> member and <code>data</code> can be used to determine when to end iteration.  <a href="bigWig_8h.html#afaeb6115f7056b209eefa9363b409ef5">More...</a><br /></td></tr>
<tr class="separator:afaeb6115f7056b209eefa9363b409ef5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a75c2894f13ba9d6917117c63565e5c42"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a75c2894f13ba9d6917117c63565e5c42">bbOverlappingEntriesIterator</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, int withString, uint32_t blocksPerIteration)</td></tr>
<tr class="memdesc:a75c2894f13ba9d6917117c63565e5c42"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates an iterator over entries in a bigBed file Iterators can be traversed with <code><a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext()</a></code> and destroyed with <code><a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy()</a></code>. Entries are in the <code>entries</code> member and <code>data</code> can be used to determine when to end iteration.  <a href="bigWig_8h.html#a75c2894f13ba9d6917117c63565e5c42">More...</a><br /></td></tr>
<tr class="separator:a75c2894f13ba9d6917117c63565e5c42"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3f15a3f526c2d9ad2f721b791bcdf956"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956">bwIteratorNext</a> (<a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *iter)</td></tr>
<tr class="memdesc:a3f15a3f526c2d9ad2f721b791bcdf956"><td class="mdescLeft">&#160;</td><td class="mdescRight">Traverses to the entries/intervals in the next group of blocks.  <a href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956">More...</a><br /></td></tr>
<tr class="separator:a3f15a3f526c2d9ad2f721b791bcdf956"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9b99f0c33d052d278d2e25044ca706e4"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4">bwIteratorDestroy</a> (<a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *iter)</td></tr>
<tr class="memdesc:a9b99f0c33d052d278d2e25044ca706e4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destroys a <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a>.  <a href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4">More...</a><br /></td></tr>
<tr class="separator:a9b99f0c33d052d278d2e25044ca706e4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29f3a6b4b6861833a35a1199666d2cf9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a29f3a6b4b6861833a35a1199666d2cf9">bwGetValues</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, int includeNA)</td></tr>
<tr class="memdesc:a29f3a6b4b6861833a35a1199666d2cf9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return all per-base bigWig values in a given interval. Given an interval (e.g., chr1:0-100), return the value at each position in a bigWig file. Positions without associated values are suppressed by default, but may be returned if <code>includeNA</code> is not 0.  <a href="bigWig_8h.html#a29f3a6b4b6861833a35a1199666d2cf9">More...</a><br /></td></tr>
<tr class="separator:a29f3a6b4b6861833a35a1199666d2cf9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af06eae8c9d405a03276c56d53e3c4fc4"><td class="memItemLeft" align="right" valign="top">double *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#af06eae8c9d405a03276c56d53e3c4fc4">bwStats</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, uint32_t nBins, enum <a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a> type)</td></tr>
<tr class="memdesc:af06eae8c9d405a03276c56d53e3c4fc4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determines per-interval bigWig statistics Can determine mean/min/max/coverage/standard deviation of values in one or more intervals in a bigWig file. You can optionally give it an interval and ask for values from X number of sub-intervals.  <a href="bigWig_8h.html#af06eae8c9d405a03276c56d53e3c4fc4">More...</a><br /></td></tr>
<tr class="separator:af06eae8c9d405a03276c56d53e3c4fc4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a18f6f370b879f855fee47f9d452ebf4b"><td class="memItemLeft" align="right" valign="top">double *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a18f6f370b879f855fee47f9d452ebf4b">bwStatsFromFull</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t end, uint32_t nBins, enum <a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a> type)</td></tr>
<tr class="memdesc:a18f6f370b879f855fee47f9d452ebf4b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Determines per-interval bigWig statistics Can determine mean/min/max/coverage/standard deviation of values in one or more intervals in a bigWig file. You can optionally give it an interval and ask for values from X number of sub-intervals. The difference with bwStats is that zoom levels are never used.  <a href="bigWig_8h.html#a18f6f370b879f855fee47f9d452ebf4b">More...</a><br /></td></tr>
<tr class="separator:a18f6f370b879f855fee47f9d452ebf4b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0dc09da6beabf0c9ea3d0ca447ddff5b"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a0dc09da6beabf0c9ea3d0ca447ddff5b">bwCreateHdr</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, int32_t maxZooms)</td></tr>
<tr class="memdesc:a0dc09da6beabf0c9ea3d0ca447ddff5b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a largely empty bigWig header Every bigWig file has a header, this creates the template for one. It also takes care of space allocation in the output write buffer.  <a href="bigWig_8h.html#a0dc09da6beabf0c9ea3d0ca447ddff5b">More...</a><br /></td></tr>
<tr class="separator:a0dc09da6beabf0c9ea3d0ca447ddff5b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a121b65a3e554f8ef3f329b5f529de4a2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structchromList__t.html">chromList_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a121b65a3e554f8ef3f329b5f529de4a2">bwCreateChromList</a> (char **chroms, uint32_t *lengths, int64_t n)</td></tr>
<tr class="memdesc:a121b65a3e554f8ef3f329b5f529de4a2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Take a list of chromosome names and lengths and return a pointer to a <a class="el" href="structchromList__t.html" title="Holds the chromosomes and their lengths.">chromList_t</a> This MUST be run before <code><a class="el" href="bigWig_8h.html#af66b538195826aa3bda7e3363cf3f201" title="Write a the header to a bigWig file. You must have already opened the output file,...">bwWriteHdr()</a></code>. Note that the input is NOT free()d!  <a href="bigWig_8h.html#a121b65a3e554f8ef3f329b5f529de4a2">More...</a><br /></td></tr>
<tr class="separator:a121b65a3e554f8ef3f329b5f529de4a2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af66b538195826aa3bda7e3363cf3f201"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#af66b538195826aa3bda7e3363cf3f201">bwWriteHdr</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *bw)</td></tr>
<tr class="memdesc:af66b538195826aa3bda7e3363cf3f201"><td class="mdescLeft">&#160;</td><td class="mdescRight">Write a the header to a bigWig file. You must have already opened the output file, created a header and a chromosome list.  <a href="bigWig_8h.html#af66b538195826aa3bda7e3363cf3f201">More...</a><br /></td></tr>
<tr class="separator:af66b538195826aa3bda7e3363cf3f201"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a11d64f7e0f8c9b7d79fe826bb97c5b59"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59">bwAddIntervals</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char **chrom, uint32_t *start, uint32_t *end, float *values, uint32_t n)</td></tr>
<tr class="memdesc:a11d64f7e0f8c9b7d79fe826bb97c5b59"><td class="mdescLeft">&#160;</td><td class="mdescRight">Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome start end value to the file. These will always be added in a new block, so you may have previously used a different storage type.  <a href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59">More...</a><br /></td></tr>
<tr class="separator:a11d64f7e0f8c9b7d79fe826bb97c5b59"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab89bcbcd986ba9a16cca29daa9329051"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051">bwAppendIntervals</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, uint32_t *start, uint32_t *end, float *values, uint32_t n)</td></tr>
<tr class="memdesc:ab89bcbcd986ba9a16cca29daa9329051"><td class="mdescLeft">&#160;</td><td class="mdescRight">Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file. If you have previously used <a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals()</a> then this will append additional entries into the previous block (or start a new one if needed).  <a href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051">More...</a><br /></td></tr>
<tr class="separator:ab89bcbcd986ba9a16cca29daa9329051"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a633635a8da1bb1e9e5f42b5557f9872a"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a">bwAddIntervalSpans</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t *start, uint32_t span, float *values, uint32_t n)</td></tr>
<tr class="memdesc:a633635a8da1bb1e9e5f42b5557f9872a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start value to the file. Each block of such entries has an associated "span", so each value describes the region chromosome:start-(start+span)  <a href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a">More...</a><br /></td></tr>
<tr class="separator:a633635a8da1bb1e9e5f42b5557f9872a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a96f517b42f51e9c97caf0b99fdca5f70"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#a96f517b42f51e9c97caf0b99fdca5f70">bwAppendIntervalSpans</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, uint32_t *start, float *values, uint32_t n)</td></tr>
<tr class="memdesc:a96f517b42f51e9c97caf0b99fdca5f70"><td class="mdescLeft">&#160;</td><td class="mdescRight">Append to a previous block of variable-step entries. If you previously used <code><a class="el" href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a" title="Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start ...">bwAddIntervalSpans()</a></code>, this will continue appending more values to the block(s) it created.  <a href="bigWig_8h.html#a96f517b42f51e9c97caf0b99fdca5f70">More...</a><br /></td></tr>
<tr class="separator:a96f517b42f51e9c97caf0b99fdca5f70"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aec467bb957caab80a06c21ff5b4bbfab"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab">bwAddIntervalSpanSteps</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, char *chrom, uint32_t start, uint32_t span, uint32_t step, float *values, uint32_t n)</td></tr>
<tr class="memdesc:aec467bb957caab80a06c21ff5b4bbfab"><td class="mdescLeft">&#160;</td><td class="mdescRight">Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file. Each block of such entries has an associated "span", "step", chromosome and start position. See the wiggle format for more details.  <a href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab">More...</a><br /></td></tr>
<tr class="separator:aec467bb957caab80a06c21ff5b4bbfab"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab4a0512c15a6647fc92cb5e3b5bca861"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="bigWig_8h.html#ab4a0512c15a6647fc92cb5e3b5bca861">bwAppendIntervalSpanSteps</a> (<a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *fp, float *values, uint32_t n)</td></tr>
<tr class="memdesc:ab4a0512c15a6647fc92cb5e3b5bca861"><td class="mdescLeft">&#160;</td><td class="mdescRight">Append to a previous block of fixed-step entries. If you previously used <code><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps()</a></code>, this will continue appending more values to the block(s) it created.  <a href="bigWig_8h.html#ab4a0512c15a6647fc92cb5e3b5bca861">More...</a><br /></td></tr>
<tr class="separator:ab4a0512c15a6647fc92cb5e3b5bca861"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>These are the functions and structured that should be used by external users. While I don't particularly recommend dealing with some of the structures (e.g., a <a class="el" href="structbigWigHdr__t.html" title="The header section of a bigWig file.">bigWigHdr_t</a>), they're described here in case you need them.</p>
<p>BTW, this library doesn't switch endianness as appropriate, since I kind of assume that there's only one type produced these days. </p>
</div><h2 class="groupheader">Macro Definition Documentation</h2>
<a id="a17aeac12ade93f0b26a203be7beacc68"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a17aeac12ade93f0b26a203be7beacc68">&#9670;&nbsp;</a></span>BIGBED_MAGIC</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define BIGBED_MAGIC&#160;&#160;&#160;0x8789F2EB</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The magic number of a bigBed file. </p>

</div>
</div>
<a id="abc55570005e3349503ee7f6d5267eb8a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abc55570005e3349503ee7f6d5267eb8a">&#9670;&nbsp;</a></span>BIGWIG_MAGIC</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define BIGWIG_MAGIC&#160;&#160;&#160;0x888FFC26</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The magic number of a bigWig file. </p>

</div>
</div>
<a id="a3d7d5829abe177defc549aaddd59e121"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3d7d5829abe177defc549aaddd59e121">&#9670;&nbsp;</a></span>CIRTREE_MAGIC</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CIRTREE_MAGIC&#160;&#160;&#160;0x78ca8c91</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The magic number of a "cirTree" block in a file. </p>

</div>
</div>
<a id="a46a626f6d8b24b07925d82cde2175864"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a46a626f6d8b24b07925d82cde2175864">&#9670;&nbsp;</a></span>DEFAULT_BLOCKSIZE</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define DEFAULT_BLOCKSIZE&#160;&#160;&#160;32768</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The default decompression buffer size in bytes. This is used to determin </p>

</div>
</div>
<a id="ac0d6303cef22d415a53d150be8f06623"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac0d6303cef22d415a53d150be8f06623">&#9670;&nbsp;</a></span>DEFAULT_nCHILDREN</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define DEFAULT_nCHILDREN&#160;&#160;&#160;64</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The default number of children per block. </p>

</div>
</div>
<a id="a28c6eb6ee75c6082e8df04dba8c7f32e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a28c6eb6ee75c6082e8df04dba8c7f32e">&#9670;&nbsp;</a></span>IDX_MAGIC</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define IDX_MAGIC&#160;&#160;&#160;0x2468ace0</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The magic number of an index block in a file. </p>

</div>
</div>
<a id="ac2496b5d01c469f90f790b933f31d0d4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac2496b5d01c469f90f790b933f31d0d4">&#9670;&nbsp;</a></span>LIBBIGWIG_CURL</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define LIBBIGWIG_CURL&#160;&#160;&#160;1</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>If 1, then this library was compiled with remote file support. </p>

</div>
</div>
<a id="afe870db159b3eed39c32be30ccc73c4e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afe870db159b3eed39c32be30ccc73c4e">&#9670;&nbsp;</a></span>LIBBIGWIG_VERSION</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define LIBBIGWIG_VERSION&#160;&#160;&#160;0.4.5</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The library version number </p>

</div>
</div>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a id="aa3e01d7486887aa111417b688bc1a22c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa3e01d7486887aa111417b688bc1a22c">&#9670;&nbsp;</a></span>bwStatsType</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>An enum that dictates the type of statistic to fetch for a given interval </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca3dc84a7fe13f0c3b468dd1fcf456ee3a"></a>doesNotExist&#160;</td><td class="fielddoc"><p>This does nothing </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca73aa25ce744f80bc0f1c0e991a509638"></a>mean&#160;</td><td class="fielddoc"><p>The mean value </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22cae478d4d7f90177e87ed05369ad732b25"></a>average&#160;</td><td class="fielddoc"><p>The mean value </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22cac7a4dba588d32e11eaa063e51c491387"></a>stdev&#160;</td><td class="fielddoc"><p>The standard deviation of the values </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22cac10cab3311c9fe30fbabf9137cd40d57"></a>dev&#160;</td><td class="fielddoc"><p>The standard deviation of the values </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca6eba708e9255d1bb06879b30b47422ff"></a>max&#160;</td><td class="fielddoc"><p>The maximum value </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca1e491e9b59d4f6891eb2929589487dfc"></a>min&#160;</td><td class="fielddoc"><p>The minimum value </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22caf866615ac99c2e47027ea68849ef849f"></a>cov&#160;</td><td class="fielddoc"><p>The number of bases covered </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca02bbe932c03913324065a5318a16e715"></a>coverage&#160;</td><td class="fielddoc"><p>The number of bases covered </p>
</td></tr>
<tr><td class="fieldname"><a id="aa3e01d7486887aa111417b688bc1a22ca3693895373771b9806a9775d16d1198b"></a>sum&#160;</td><td class="fielddoc"><p>The sum of per-base values </p>
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="a1c53fa1c835b2527afb5028d21111ff4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1c53fa1c835b2527afb5028d21111ff4">&#9670;&nbsp;</a></span>bbDestroyOverlappingEntries()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void bbDestroyOverlappingEntries </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbbOverlappingEntries__t.html">bbOverlappingEntries_t</a> *&#160;</td>
          <td class="paramname"><em>o</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Frees space allocated by <code>bbGetOverlappingEntries</code> </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">o</td><td>A valid <code><a class="el" href="structbbOverlappingEntries__t.html" title="Holds interval:str associations.">bbOverlappingEntries_t</a></code> pointer. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a3ae987bbf528cc193bbbbd7536668e89" title="Return bigBed entries overlapping an interval. Find all bigBed entries overlapping a range and return...">bbGetOverlappingEntries</a> </dd></dl>

</div>
</div>
<a id="a3ae987bbf528cc193bbbbd7536668e89"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3ae987bbf528cc193bbbbd7536668e89">&#9670;&nbsp;</a></span>bbGetOverlappingEntries()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbbOverlappingEntries__t.html">bbOverlappingEntries_t</a>* bbGetOverlappingEntries </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>withString</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return bigBed entries overlapping an interval. Find all bigBed entries overlapping a range and returns them. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. This MUST be for a bigBed file! </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">withString</td><td>If not 0, return the string associated with each entry in the output. If 0, there are no associated strings returned. This is useful if the only information needed are the locations of the entries, which require significantly less memory. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error or no overlapping values, otherwise a <code><a class="el" href="structbbOverlappingEntries__t.html" title="Holds interval:str associations.">bbOverlappingEntries_t</a> *</code> holding the intervals and (optionally) the associated string. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="structbbOverlappingEntries__t.html" title="Holds interval:str associations.">bbOverlappingEntries_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a1c53fa1c835b2527afb5028d21111ff4" title="Frees space allocated by bbGetOverlappingEntries">bbDestroyOverlappingEntries</a> </dd></dl>

</div>
</div>
<a id="a6de19dc3a3e25e1b10a61b941f299862"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6de19dc3a3e25e1b10a61b941f299862">&#9670;&nbsp;</a></span>bbGetSQL()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* bbGetSQL </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns a string containing the SQL entry (or NULL). The "auto SQL" field contains the names and value types of the entries in each bigBed entry. If you need to parse a particular value out of each entry, then you'll need to first parse this. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The file pointer to a valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A char *, which you MUST free! </dd></dl>

</div>
</div>
<a id="a592fb218273e1f18d97448c88588df19"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a592fb218273e1f18d97448c88588df19">&#9670;&nbsp;</a></span>bbIsBigBed()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bbIsBigBed </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>fname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">CURLcode(*)(CURL *)&#160;</td>
          <td class="paramname"><em>callBack</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Determine is a file is a bigBed file. This function will quickly check either local or remote files to determine if they appear to be valid bigWig files. This can be determined by reading the first 4 bytes of the file. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fname</td><td>The file name or URL (http, https, and ftp are supported) </td></tr>
    <tr><td class="paramname">callBack</td><td>An optional user-supplied function. This is applied to remote connections so users can specify things like proxy and password information. See <code>test/testRemote</code> for an example. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>1 if the file appears to be bigWig, otherwise 0. </dd></dl>

</div>
</div>
<a id="aa1f2b92d87ce0edc52d75ce8351e03a5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa1f2b92d87ce0edc52d75ce8351e03a5">&#9670;&nbsp;</a></span>bbOpen()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a>* bbOpen </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>fname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">CURLcode(*)(CURL *)&#160;</td>
          <td class="paramname"><em>callBack</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Opens a local or remote bigBed file. This will open a local or remote bigBed file. Note that this file format can only be read and NOT written! </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fname</td><td>The file name or URL (http, https, and ftp are supported) </td></tr>
    <tr><td class="paramname">callBack</td><td>An optional user-supplied function. This is applied to remote connections so users can specify things like proxy and password information. See <code>test/testRemote</code> for an example. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> * on success and NULL on error. </dd></dl>

</div>
</div>
<a id="a75c2894f13ba9d6917117c63565e5c42"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a75c2894f13ba9d6917117c63565e5c42">&#9670;&nbsp;</a></span>bbOverlappingEntriesIterator()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a>* bbOverlappingEntriesIterator </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>withString</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>blocksPerIteration</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Creates an iterator over entries in a bigBed file Iterators can be traversed with <code><a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext()</a></code> and destroyed with <code><a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy()</a></code>. Entries are in the <code>entries</code> member and <code>data</code> can be used to determine when to end iteration. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. This MUST be for a bigBed file! </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">withString</td><td>Whether the returned entries should include their associated strings. </td></tr>
    <tr><td class="paramname">blocksPerIteration</td><td>The number of blocks (internal groupings of entries in bigBed files) to return per iteration. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error, otherwise a <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> pointer </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a3ae987bbf528cc193bbbbd7536668e89" title="Return bigBed entries overlapping an interval. Find all bigBed entries overlapping a range and return...">bbGetOverlappingEntries</a> </dd>
<dd>
<a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy</a> </dd></dl>

</div>
</div>
<a id="a11d64f7e0f8c9b7d79fe826bb97c5b59"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a11d64f7e0f8c9b7d79fe826bb97c5b59">&#9670;&nbsp;</a></span>bwAddIntervals()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAddIntervals </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char **&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome start end value to the file. These will always be added in a new block, so you may have previously used a different storage type. </p>
<p>In general it's more efficient to use the bwAppend* functions, but then you MUST know that the previously written block is of the same type. In other words, you can only use <a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051" title="Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file....">bwAppendIntervals()</a> after <a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals()</a> or a previous <a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051" title="Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file....">bwAppendIntervals()</a>. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">chrom</td><td>A list of chromosomes, of length <code>n</code>. </td></tr>
    <tr><td class="paramname">start</td><td>A list of start positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">end</td><td>A list of end positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051" title="Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file....">bwAppendIntervals</a> </dd></dl>

</div>
</div>
<a id="a633635a8da1bb1e9e5f42b5557f9872a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a633635a8da1bb1e9e5f42b5557f9872a">&#9670;&nbsp;</a></span>bwAddIntervalSpans()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAddIntervalSpans </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>span</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start value to the file. Each block of such entries has an associated "span", so each value describes the region chromosome:start-(start+span) </p>
<p>This will always start a new block of values. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">chrom</td><td>A list of chromosomes, of length <code>n</code>. </td></tr>
    <tr><td class="paramname">start</td><td>A list of start positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">span</td><td>The span of each entry (the must all be the same). </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a96f517b42f51e9c97caf0b99fdca5f70" title="Append to a previous block of variable-step entries. If you previously used bwAddIntervalSpans(),...">bwAppendIntervalSpans</a> </dd></dl>

</div>
</div>
<a id="aec467bb957caab80a06c21ff5b4bbfab"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aec467bb957caab80a06c21ff5b4bbfab">&#9670;&nbsp;</a></span>bwAddIntervalSpanSteps()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAddIntervalSpanSteps </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>span</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>step</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file. Each block of such entries has an associated "span", "step", chromosome and start position. See the wiggle format for more details. </p>
<p>This will always start a new block of values. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">chrom</td><td>The chromosome that the entries describe. </td></tr>
    <tr><td class="paramname">start</td><td>The starting position of the block of entries. </td></tr>
    <tr><td class="paramname">span</td><td>The span of each entry (i.e., the number of bases it describes). </td></tr>
    <tr><td class="paramname">step</td><td>The step between entry start positions. </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps</a> </dd></dl>

</div>
</div>
<a id="ab89bcbcd986ba9a16cca29daa9329051"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab89bcbcd986ba9a16cca29daa9329051">&#9670;&nbsp;</a></span>bwAppendIntervals()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAppendIntervals </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file. If you have previously used <a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals()</a> then this will append additional entries into the previous block (or start a new one if needed). </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">start</td><td>A list of start positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">end</td><td>A list of end positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Do NOT use this after <code><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps()</a></code>, <code><a class="el" href="bigWig_8h.html#ab4a0512c15a6647fc92cb5e3b5bca861" title="Append to a previous block of fixed-step entries. If you previously used bwAddIntervalSpanSteps(),...">bwAppendIntervalSpanSteps()</a></code>, <code><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps()</a></code>, or <code><a class="el" href="bigWig_8h.html#ab4a0512c15a6647fc92cb5e3b5bca861" title="Append to a previous block of fixed-step entries. If you previously used bwAddIntervalSpanSteps(),...">bwAppendIntervalSpanSteps()</a></code>. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals</a> </dd></dl>

</div>
</div>
<a id="a96f517b42f51e9c97caf0b99fdca5f70"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a96f517b42f51e9c97caf0b99fdca5f70">&#9670;&nbsp;</a></span>bwAppendIntervalSpans()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAppendIntervalSpans </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Append to a previous block of variable-step entries. If you previously used <code><a class="el" href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a" title="Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start ...">bwAddIntervalSpans()</a></code>, this will continue appending more values to the block(s) it created. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">start</td><td>A list of start positions of length<code>n</code>. </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Do NOT use this after <code><a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals()</a></code>, <code><a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051" title="Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file....">bwAppendIntervals()</a></code>, <code><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps()</a></code> or <code><a class="el" href="bigWig_8h.html#ab4a0512c15a6647fc92cb5e3b5bca861" title="Append to a previous block of fixed-step entries. If you previously used bwAddIntervalSpanSteps(),...">bwAppendIntervalSpanSteps()</a></code> </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a" title="Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start ...">bwAddIntervalSpans</a> </dd></dl>

</div>
</div>
<a id="ab4a0512c15a6647fc92cb5e3b5bca861"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab4a0512c15a6647fc92cb5e3b5bca861">&#9670;&nbsp;</a></span>bwAppendIntervalSpanSteps()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwAppendIntervalSpanSteps </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float *&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Append to a previous block of fixed-step entries. If you previously used <code><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps()</a></code>, this will continue appending more values to the block(s) it created. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The output file pointer. </td></tr>
    <tr><td class="paramname">values</td><td>A list of values of length<code>n</code>. </td></tr>
    <tr><td class="paramname">n</td><td>The length of the aforementioned lists. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and another value on error. </dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Do NOT use this after <code><a class="el" href="bigWig_8h.html#a11d64f7e0f8c9b7d79fe826bb97c5b59" title="Write a new block of bedGraph-like intervals to a bigWig file Adds entries of the form: chromosome st...">bwAddIntervals()</a></code>, <code><a class="el" href="bigWig_8h.html#ab89bcbcd986ba9a16cca29daa9329051" title="Append bedGraph-like intervals to a previous block of bedGraph-like intervals in a bigWig file....">bwAppendIntervals()</a></code>, <code><a class="el" href="bigWig_8h.html#a633635a8da1bb1e9e5f42b5557f9872a" title="Add a new block of variable-step entries to a bigWig file Adds entries for the form chromosome start ...">bwAddIntervalSpans()</a></code> or <code><a class="el" href="bigWig_8h.html#a96f517b42f51e9c97caf0b99fdca5f70" title="Append to a previous block of variable-step entries. If you previously used bwAddIntervalSpans(),...">bwAppendIntervalSpans()</a></code> </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#aec467bb957caab80a06c21ff5b4bbfab" title="Add a new block of fixed-step entries to a bigWig file Adds entries for the form value to the file....">bwAddIntervalSpanSteps</a> </dd></dl>

</div>
</div>
<a id="af1f5d8a9bf0a96034b2ba3f3b3ee679a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af1f5d8a9bf0a96034b2ba3f3b3ee679a">&#9670;&nbsp;</a></span>bwCleanup()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void bwCleanup </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The counterpart to bwInit, this cleans up curl. </p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a4aa7fa5e6146a2719feb8815c9bccd62" title="Initializes curl and global variables. This MUST be called before other functions (at least if you wa...">bwInit</a> </dd></dl>

</div>
</div>
<a id="ae9041b92bc3f69533fe6dc1711bbf485"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae9041b92bc3f69533fe6dc1711bbf485">&#9670;&nbsp;</a></span>bwClose()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void bwClose </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Closes a <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> and frees up allocated memory This closes both bigWig and bigBed files. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The file pointer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a121b65a3e554f8ef3f329b5f529de4a2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a121b65a3e554f8ef3f329b5f529de4a2">&#9670;&nbsp;</a></span>bwCreateChromList()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structchromList__t.html">chromList_t</a>* bwCreateChromList </td>
          <td>(</td>
          <td class="paramtype">char **&#160;</td>
          <td class="paramname"><em>chroms</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>lengths</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int64_t&#160;</td>
          <td class="paramname"><em>n</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Take a list of chromosome names and lengths and return a pointer to a <a class="el" href="structchromList__t.html" title="Holds the chromosomes and their lengths.">chromList_t</a> This MUST be run before <code><a class="el" href="bigWig_8h.html#af66b538195826aa3bda7e3363cf3f201" title="Write a the header to a bigWig file. You must have already opened the output file,...">bwWriteHdr()</a></code>. Note that the input is NOT free()d! </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">chroms</td><td>A list of chromosomes. </td></tr>
    <tr><td class="paramname">lengths</td><td>The length of each chromosome. </td></tr>
    <tr><td class="paramname">n</td><td>The number of chromosomes (thus, the length of <code>chroms</code> and <code>lengths</code>) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A pointer to a <a class="el" href="structchromList__t.html" title="Holds the chromosomes and their lengths.">chromList_t</a> or NULL on error. </dd></dl>

</div>
</div>
<a id="a0dc09da6beabf0c9ea3d0ca447ddff5b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0dc09da6beabf0c9ea3d0ca447ddff5b">&#9670;&nbsp;</a></span>bwCreateHdr()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwCreateHdr </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int32_t&#160;</td>
          <td class="paramname"><em>maxZooms</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create a largely empty bigWig header Every bigWig file has a header, this creates the template for one. It also takes care of space allocation in the output write buffer. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The bigWigFile_t* that you want to write to. </td></tr>
    <tr><td class="paramname">maxZooms</td><td>The maximum number of zoom levels. If you specify 0 then there will be no zoom levels. A value &lt;0 or &gt; 65535 will result in a maximum of 10. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success. </dd></dl>

</div>
</div>
<a id="a6a3f9298129e7fa061707739a96b36f3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6a3f9298129e7fa061707739a96b36f3">&#9670;&nbsp;</a></span>bwDestroyOverlappingIntervals()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void bwDestroyOverlappingIntervals </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a> *&#160;</td>
          <td class="paramname"><em>o</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Frees space allocated by <code>bwGetOverlappingIntervals</code> </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">o</td><td>A valid <code><a class="el" href="structbwOverlappingIntervals__t.html" title="Holds interval:value associations.">bwOverlappingIntervals_t</a></code> pointer. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#aa1ac8480a8fdf24c53b73970149e359b" title="Return bigWig entries overlapping an interval. Find all bigWig entries overlapping a range and return...">bwGetOverlappingIntervals</a> </dd></dl>

</div>
</div>
<a id="aa1ac8480a8fdf24c53b73970149e359b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa1ac8480a8fdf24c53b73970149e359b">&#9670;&nbsp;</a></span>bwGetOverlappingIntervals()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a>* bwGetOverlappingIntervals </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return bigWig entries overlapping an interval. Find all bigWig entries overlapping a range and returns them, including their associated values. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. This MUST be for a bigWig file! </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error or no overlapping values, otherwise a <code><a class="el" href="structbwOverlappingIntervals__t.html" title="Holds interval:value associations.">bwOverlappingIntervals_t</a> *</code> holding the values and intervals. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="structbwOverlappingIntervals__t.html" title="Holds interval:value associations.">bwOverlappingIntervals_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a6a3f9298129e7fa061707739a96b36f3" title="Frees space allocated by bwGetOverlappingIntervals">bwDestroyOverlappingIntervals</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a29f3a6b4b6861833a35a1199666d2cf9" title="Return all per-base bigWig values in a given interval. Given an interval (e.g., chr1:0-100),...">bwGetValues</a> </dd></dl>

</div>
</div>
<a id="af017214ff795d4d738cf679cd4a55b6c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af017214ff795d4d738cf679cd4a55b6c">&#9670;&nbsp;</a></span>bwGetTid()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t bwGetTid </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Converts between chromosome name and ID. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer </td></tr>
    <tr><td class="paramname">chrom</td><td>A chromosome name </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>An ID, -1 will be returned on error (note that this is an unsigned value, so that's ~4 billion. bigWig/bigBed files can't store that many chromosomes anyway. </dd></dl>

</div>
</div>
<a id="a29f3a6b4b6861833a35a1199666d2cf9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a29f3a6b4b6861833a35a1199666d2cf9">&#9670;&nbsp;</a></span>bwGetValues()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbwOverlappingIntervals__t.html">bwOverlappingIntervals_t</a>* bwGetValues </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>includeNA</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return all per-base bigWig values in a given interval. Given an interval (e.g., chr1:0-100), return the value at each position in a bigWig file. Positions without associated values are suppressed by default, but may be returned if <code>includeNA</code> is not 0. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">includeNA</td><td>If not 0, report NA values as well (as NA). </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error or no overlapping values, otherwise a <code><a class="el" href="structbwOverlappingIntervals__t.html" title="Holds interval:value associations.">bwOverlappingIntervals_t</a> *</code> holding the values and positions. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="structbwOverlappingIntervals__t.html" title="Holds interval:value associations.">bwOverlappingIntervals_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a6a3f9298129e7fa061707739a96b36f3" title="Frees space allocated by bwGetOverlappingIntervals">bwDestroyOverlappingIntervals</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#aa1ac8480a8fdf24c53b73970149e359b" title="Return bigWig entries overlapping an interval. Find all bigWig entries overlapping a range and return...">bwGetOverlappingIntervals</a> </dd></dl>

</div>
</div>
<a id="a4aa7fa5e6146a2719feb8815c9bccd62"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4aa7fa5e6146a2719feb8815c9bccd62">&#9670;&nbsp;</a></span>bwInit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwInit </td>
          <td>(</td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>bufSize</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initializes curl and global variables. This <em>MUST</em> be called before other functions (at least if you want to connect to remote files). For remote file, curl must be initialized and regions of a file read into an internal buffer. If the buffer is too small then an excessive number of connections will be made. If the buffer is too large than more data than required is fetched. 128KiB is likely sufficient for most needs. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bufSize</td><td>The internal buffer size used for remote connection. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#af1f5d8a9bf0a96034b2ba3f3b3ee679a" title="The counterpart to bwInit, this cleans up curl.">bwCleanup</a> </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>0 on success and 1 on error. </dd></dl>

</div>
</div>
<a id="a83cb23e15fed718ba77576e41865dab9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a83cb23e15fed718ba77576e41865dab9">&#9670;&nbsp;</a></span>bwIsBigWig()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwIsBigWig </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>fname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">CURLcode(*)(CURL *)&#160;</td>
          <td class="paramname"><em>callBack</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Determine if a file is a bigWig file. This function will quickly check either local or remote files to determine if they appear to be valid bigWig files. This can be determined by reading the first 4 bytes of the file. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fname</td><td>The file name or URL (http, https, and ftp are supported) </td></tr>
    <tr><td class="paramname">callBack</td><td>An optional user-supplied function. This is applied to remote connections so users can specify things like proxy and password information. See <code>test/testRemote</code> for an example. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>1 if the file appears to be bigWig, otherwise 0. </dd></dl>

</div>
</div>
<a id="a9b99f0c33d052d278d2e25044ca706e4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9b99f0c33d052d278d2e25044ca706e4">&#9670;&nbsp;</a></span>bwIteratorDestroy()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void bwIteratorDestroy </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *&#160;</td>
          <td class="paramname"><em>iter</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Destroys a <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">iter</td><td>The <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> that should be destroyed </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a3f15a3f526c2d9ad2f721b791bcdf956"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3f15a3f526c2d9ad2f721b791bcdf956">&#9670;&nbsp;</a></span>bwIteratorNext()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a>* bwIteratorNext </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a> *&#160;</td>
          <td class="paramname"><em>iter</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Traverses to the entries/intervals in the next group of blocks. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">iter</td><td>A <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> pointer that is updated (or destroyed on error) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error, otherwise a <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> pointer with the intervals or entries from the next set of blocks. </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy</a> </dd></dl>

</div>
</div>
<a id="a55e46bf04f13da31a3971044b85c9243"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a55e46bf04f13da31a3971044b85c9243">&#9670;&nbsp;</a></span>bwOpen()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a>* bwOpen </td>
          <td>(</td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>fname</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">CURLcode(*)(CURL *)&#160;</td>
          <td class="paramname"><em>callBack</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>mode</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Opens a local or remote bigWig file. This will open a local or remote bigWig file. Writing of local bigWig files is also supported. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fname</td><td>The file name or URL (http, https, and ftp are supported) </td></tr>
    <tr><td class="paramname">callBack</td><td>An optional user-supplied function. This is applied to remote connections so users can specify things like proxy and password information. See <code>test/testRemote</code> for an example. </td></tr>
    <tr><td class="paramname">mode</td><td>The mode, by default "r". Both local and remote files can be read, but only local files can be written. For files being written the callback function is ignored. If and only if the mode contains "w" will the file be opened for writing (in all other cases the file will be opened for reading. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> * on success and NULL on error. </dd></dl>

</div>
</div>
<a id="afaeb6115f7056b209eefa9363b409ef5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afaeb6115f7056b209eefa9363b409ef5">&#9670;&nbsp;</a></span>bwOverlappingIntervalsIterator()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structbwOverlapIterator__t.html">bwOverlapIterator_t</a>* bwOverlappingIntervalsIterator </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>blocksPerIteration</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Creates an iterator over intervals in a bigWig file Iterators can be traversed with <code><a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext()</a></code> and destroyed with <code><a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy()</a></code>. Intervals are in the <code>intervals</code> member and <code>data</code> can be used to determine when to end iteration. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>A valid <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. This MUST be for a bigWig file! </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">blocksPerIteration</td><td>The number of blocks (internal groupings of intervals in bigWig files) to return per iteration. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>NULL on error, otherwise a <a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> pointer </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="structbwOverlapIterator__t.html" title="A structure to hold iterations One of intervals and entries should be used to access records from big...">bwOverlapIterator_t</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a3f15a3f526c2d9ad2f721b791bcdf956" title="Traverses to the entries/intervals in the next group of blocks.">bwIteratorNext</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a9b99f0c33d052d278d2e25044ca706e4" title="Destroys a bwOverlapIterator_t.">bwIteratorDestroy</a> </dd></dl>

</div>
</div>
<a id="af06eae8c9d405a03276c56d53e3c4fc4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af06eae8c9d405a03276c56d53e3c4fc4">&#9670;&nbsp;</a></span>bwStats()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double* bwStats </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>nBins</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">enum <a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a>&#160;</td>
          <td class="paramname"><em>type</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Determines per-interval bigWig statistics Can determine mean/min/max/coverage/standard deviation of values in one or more intervals in a bigWig file. You can optionally give it an interval and ask for values from X number of sub-intervals. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The file from which to extract statistics. </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">nBins</td><td>The number of bins within the interval to calculate statistics for. </td></tr>
    <tr><td class="paramname">type</td><td>The type of statistic. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a> </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>A pointer to an array of double precission floating point values. Note that bigWig files only hold 32-bit values, so this is done to help prevent overflows. </dd></dl>

</div>
</div>
<a id="a18f6f370b879f855fee47f9d452ebf4b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a18f6f370b879f855fee47f9d452ebf4b">&#9670;&nbsp;</a></span>bwStatsFromFull()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double* bwStatsFromFull </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>fp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&#160;</td>
          <td class="paramname"><em>chrom</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>nBins</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">enum <a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a>&#160;</td>
          <td class="paramname"><em>type</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Determines per-interval bigWig statistics Can determine mean/min/max/coverage/standard deviation of values in one or more intervals in a bigWig file. You can optionally give it an interval and ask for values from X number of sub-intervals. The difference with bwStats is that zoom levels are never used. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">fp</td><td>The file from which to extract statistics. </td></tr>
    <tr><td class="paramname">chrom</td><td>A valid chromosome name. </td></tr>
    <tr><td class="paramname">start</td><td>The start position of the interval. This is 0-based half open, so 0 is the first base. </td></tr>
    <tr><td class="paramname">end</td><td>The end position of the interval. Again, this is 0-based half open, so 100 will include the 100th base...which is at position 99. </td></tr>
    <tr><td class="paramname">nBins</td><td>The number of bins within the interval to calculate statistics for. </td></tr>
    <tr><td class="paramname">type</td><td>The type of statistic. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#aa3e01d7486887aa111417b688bc1a22c">bwStatsType</a> </dd></dl>
<dl class="section return"><dt>Returns</dt><dd>A pointer to an array of double precission floating point values. Note that bigWig files only hold 32-bit values, so this is done to help prevent overflows. </dd></dl>

</div>
</div>
<a id="af66b538195826aa3bda7e3363cf3f201"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af66b538195826aa3bda7e3363cf3f201">&#9670;&nbsp;</a></span>bwWriteHdr()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int bwWriteHdr </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structbigWigFile__t.html">bigWigFile_t</a> *&#160;</td>
          <td class="paramname"><em>bw</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Write a the header to a bigWig file. You must have already opened the output file, created a header and a chromosome list. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">bw</td><td>The output <a class="el" href="structbigWigFile__t.html" title="A structure that holds everything needed to access a bigWig file.">bigWigFile_t</a> pointer. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="bigWig_8h.html#a0dc09da6beabf0c9ea3d0ca447ddff5b" title="Create a largely empty bigWig header Every bigWig file has a header, this creates the template for on...">bwCreateHdr</a> </dd>
<dd>
<a class="el" href="bigWig_8h.html#a121b65a3e554f8ef3f329b5f529de4a2" title="Take a list of chromosome names and lengths and return a pointer to a chromList_t This MUST be run be...">bwCreateChromList</a> </dd></dl>

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sun Nov 8 2020 13:48:36 for libBigWig by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.17
</small></address>
</body>
</html>
